package inheritance;

public class RaceCarDemo {

	public static void main(String[] args) {
		
		RaceCar raceCar = new RaceCar(1234,"NASCAR", "M20014"," Red Blue", 199,2014);
	
		// inherited methods from Car SuperClass
		
			raceCar.start();
			raceCar.setStarted(true);
			raceCar.changeColor();
		
		    System.out.println("set the car status to True : raceCar.setStarted(true)");
		
		// RaceCar special method
		
			raceCar.race();
		   // raceCar.accelerateSpeed(5);
		    int currentSpeed = raceCar.getCurrentSpeed();
		
		//Printing the current speed of RaceCar.
		    System.out.println("My current Speed: "+currentSpeed);
		  //  System.out.println("My current Speed: "+raceCar.getCurrentSpeed());
		    System.out.println("  NasCar  maximum speed is  :"+raceCar.getMaxSpeed());
	}

}
